package com.leyou.trade.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.leyou.common.dto.PageDTO;
import com.leyou.trade.dto.OrderFormDTO;
import com.leyou.trade.dto.OrderWithDetailDTO;
import com.leyou.trade.dto.OrderListDTO;
import com.leyou.trade.entity.Order;
import com.leyou.trade.entity.OrderDetail;

import java.util.Map;

/**
 * @author 虎哥
 */
public interface OrderService extends IService<Order> {
    PageDTO<OrderListDTO> getOrderByUserIdAndStatus(Long userId, Integer status,Integer page);

    Long createOrder(OrderFormDTO orderFormDTO);

    String getPayUrl(Long id);

    void handleNotify(Map<String, String> data);

    Integer queryOrderStatusById(Long orderId);

    void evictOrder(Long orderId);

    Boolean cancelOrder(Long orderId);

    //订单查询
    PageDTO<OrderWithDetailDTO> queryOrderByKey( String key, Integer status, Integer page, Integer rows );


    void sendMsg( Long orderId );
}